module.exports = {
    devServer: {
        proxy: {
            "^/api": {
                target: "http://localhost:3008",
                changeOrigin: true,
            },
            "^/daily": {
                target: "http://sentence.iciba.com",
                ws: false,
                changeOrigin: true,
                pathRewrite: { "^/daily": "" },
            },
        },
    },
    chainWebpack: (config) => {
        config.plugin("define").tap((definitions) => {
            Object.assign(definitions[0], {
                __VUE_OPTIONS_API__: "true",
                __VUE_PROD_DEVTOOLS__: "false",
                __VUE_PROD_HYDRATION_MISMATCH_DETAILS__: "false",
            });

            return definitions;
        });
    },
};
